package com.uwo.house.config;

import com.uwo.house.beans.User;
import org.apache.shiro.authc.AuthenticationToken;

/**
 * Created by yanhao on 2017/7/16.
 */
public class JWTAuthenticationToken implements AuthenticationToken {

    private Object principal;
    private Object credentials;
    private boolean isLogin;
    private String token;
    private Long expireTime;
    private User user;
    private String provider;

    public JWTAuthenticationToken(Object principal, Object credentials, String provider) {
        this.principal = principal;
        this.credentials = credentials;
        this.provider = provider;
    }

    public String getProvider() {
        return provider;
    }

    public void setProvider(String provider) {
        this.provider = provider;
    }

    public Object getPrincipal() {
        return principal;
    }

    public Object getCredentials() {
        return credentials;
    }

    public boolean isLogin() {
        return isLogin;
    }

    public Long getExpireTime() {
        return expireTime;
    }

    public void setExpireTime(Long expireTime) {
        this.expireTime = expireTime;
    }

    public void setLogin(boolean login) {
        isLogin = login;
    }

    public void setUser(User user) {
        this.user = user;
    }

    public User getUser() {
        return user;
    }

    public String getToken() {
        return token;
    }

    public void setToken(String token) {
        this.token = token;
    }
}
